package com.vrv.app.cyberspace.modules.sys.controller;

import com.vrv.app.cyberspace.common.utils.HttpContextUtils;
import com.vrv.app.cyberspace.modules.sys.entity.UserTable;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * @Description 
 * @Author by sm
 * @Create 2018-01-08 16:00
 */

public abstract class BaseController {
    protected Logger logger = LoggerFactory.getLogger(getClass());

    protected UserTable getUser() {
        return (UserTable) HttpContextUtils.getHttpServletRequest().getSession().getAttribute("user");
    }

    protected String getUserId() {
        return getUser().getLinkdoodID();
    }
}
